<?php get_header(); ?>
<div id="accordion">
	<?php include_once (TEMPLATEPATH . '/inc/menu-home.php' ); ?>	
    <div class="panel active hasdata">
		<div class="pink news-menu" rel="pushstate"></div>
		<div class="panelContent p2">
			<div class="container-860">				
				<section class="container-548 news">
					<h1>NEWS</h1>
					<?php 
					if (have_posts()) : while (have_posts()) : the_post(); 		
						$supersized 		= get_post_meta(get_the_ID(), 'bg-supersized', true);			
						$slides = array();
						if($supersized != NULL && !empty($supersized)):
							foreach($supersized as  $photo_id)
								$slides[] = wp_get_attachment_image_src($photo_id, 'full');
						endif;						
					?>
		
						<h4><?php the_title();?></h4>
						<h5>PUBLISHED: <?php the_time('F jS, Y'); ?></h5>
						
						<?php include (TEMPLATEPATH . '/inc/share.php' ); ?>
						
						<div id="slider-news" class="royalSlider default haszoom">		
							<ul class="royalSlidesContainer">
							<?php if(!empty($slides)): foreach($slides as $slide): ?>
								<li class="royalSlide">
									<img class="royalImage" src="<?php echo $slide[0]?>" width="100%" height="100%"/>
									<div class="royalCaption">
										<a href="<?php echo $slide[0]?>" rel="lightbox" class="zoom"></a>
									</div> 				
								</li>
							<?php endforeach; endif; ?>
							</ul>		
						</div>	    		
						<div class="content"><?php the_content(); ?></div>				
						<script>
							$(document).ready(function() {
								$("#slider-news").royalSlider({
									captionShowEffects:["moveleft", "fade"],
									imageScaleMode: "fill",				
									slideshowDelay:5000,				
								}); 
								if (!/android|iphone|ipod|series60|symbian|windows ce|blackberry/i.test(navigator.userAgent)) {
									jQuery(function($) {
										$("a[rel^='lightbox']").picbox({/* Put custom options here */}, null, function(el) {
											return (this == el) || ((this.rel.length > 8) && (this.rel == el.rel));
										});
									});
								}
							});		
						</script>	
					<?php endwhile; endif; ?>
					<?php include_once (TEMPLATEPATH . '/inc/language-nav.php' ); ?>
				</section>
			</div>	
		</div>
	</div>    
	<?php include_once (TEMPLATEPATH . '/inc/menu-works.php' ); ?>
	<?php include_once (TEMPLATEPATH . '/inc/menu-contact.php' ); ?>
	<?php include_once (TEMPLATEPATH . '/inc/menu-about.php' ); ?>    
</div>
<?php get_footer(); ?>